powered by
node_exogenous tags exogenous variables given an exposure and outcome. ggdag_exogenous plots all exogenous variables. See dagitty::exogenousVariables() for details.
node_exogenous
ggdag_exogenous
dagitty::exogenousVariables()
node_exogenous(.dag, ...)ggdag_exogenous( .tdy_dag, ..., node_size = 16, text_size = 3.88, edge_type = "link_arc", label_size = text_size, text_col = "white", label_col = text_col, node = TRUE, stylized = FALSE, text = TRUE, use_labels = NULL )
ggdag_exogenous( .tdy_dag, ..., node_size = 16, text_size = 3.88, edge_type = "link_arc", label_size = text_size, text_col = "white", label_col = text_col, node = TRUE, stylized = FALSE, text = TRUE, use_labels = NULL )
a tidy_dagitty with an exogenous column for exogenous variables or a ggplot
tidy_dagitty
exogenous
ggplot
input graph, an object of class tidy_dagitty or dagitty
dagitty
additional arguments passed to tidy_dagitty()
tidy_dagitty()
size of DAG node
size of DAG text
a character vector, the edge geom to use. One of: "link_arc", which accounts for directed and bidirected edges, "link", "arc", or "diagonal"
size of label text
color of DAG text
color of label text
logical. Should nodes be included in the DAG?
logical. Should DAG nodes be stylized? If so, use geom_dag_nodes and if not use geom_dag_point
geom_dag_nodes
geom_dag_point
logical. Should text be included in the DAG?
a string. Variable to use for geom_dag_repel_label(). Default is NULL.
geom_dag_repel_label()
NULL
dag <- dagify(y ~ x1 + x2 + x3, b ~ x1 + x2) ggdag_exogenous(dag) node_exogenous(dag)
Run the code above in your browser using DataLab